<?php $this->header(); ?>
<div class="wrap">

    <!-- start -->
    <div class="nav">
        <div class="return"><a href="/?g=Admin&m=Category&a=index">返回上一级</a></div>
        <ul class="cc">
            <li class="current"><a href="/?g=Admin&m=Category&a=<?php echo ACTION;echo $_GET['id']? "&id={$_GET['id']}": ''; ?>" ><?php echo $title; ?></a></li>
        </ul>
    </div>
    <form class="J_ajaxForm" action="<?php echo $actionUrl; ?>" method="post" enctype="multipart/form-data">
        <div class="h_a">分类内容</div>
        <div class="table_full">
            <table width="100%">
                <col class="th" />
                <col/>

                <tr>
                    <th>分类级别</th>
                    <td>
                        <select name="parent_id">
                            <option value="0">顶层分类</option>
                            <?php echo $tree; ?>
                        </select>
                    </td>
                </tr>
                <tr>
                    <th>模型类型</th>
                    <td>
                        <select name="model_id" class="c_model_id">
                            <?php echo $modelOption; ?>
                            <option value="-1" <?php if($model_id == '-1'){echo 'selected="selected"';} ?>>外部链接</option>
                        </select>
                    </td>
                </tr>
                <tr class="c_url" style="display: none">
                    <th>链接地址</th>
                    <td>
                        <input name="url" type="text" class="input length_5" aria-label="" accesskey="" placeholder="" speech="" value="<?php echo $url; ?>">
                    </td>
                </tr>
                <tr>
                    <th>分类名称</th>
                    <td>
                        <input name="cate_name" type="text" class="input length_5" aria-label="" accesskey="" placeholder="" speech="" value="<?php echo $cate_name; ?>">
                    </td>
                </tr>
                <tr>
                    <th>别名</th>
                    <td>
                        <input name="aliases" type="text" class="input length_5" aria-label="" accesskey="" placeholder="" speech="" value="<?php echo $aliases; ?>">
                    </td>
                </tr>
                <tr>
                    <th>关键词</th>
                    <td>
                        <input name="keyword" type="text" class="input length_5" aria-label="关键词" accesskey="s" placeholder="关键词" speech="" value="<?php echo $keyword; ?>">
                    </td>
                </tr>
                <tr>
                    <th>描述</th>
                    <td>
                        <textarea name="description" cols="55"><?php echo $description; ?></textarea>
                    </td>
                </tr>
                <tr>
                    <th>略缩图</th>
                    <td>
                        <?php echo $func->formList($thumb); ?>
                    </td>
                </tr>
                <tr>
                    <th>是否导航</th>
                    <td>
                        <label><input type="radio" name="is_nav" value="0" <?php if (!empty($_GET['id']) && $is_nav == 0): ?>checked="checked"<?php endif; ?>><span>否</span></label>
                        <label><input type="radio" name="is_nav" value="1" <?php if (!empty($_GET['id']) && $is_nav == 1): ?>checked="checked"<?php elseif (empty($_GET['id'])): ?>checked="checked"<?php endif; ?>><span>是</span></label>
                    </td>
                </tr>
                <tr>
                    <th>排序</th>
                    <td>
                        <input name="listsort" type="text" class="input length_1" aria-label="" accesskey="" placeholder="" speech="" value="<?php echo $listsort; ?>">
                    </td>
                </tr>

            </table>
        </div>
        <div class="btn_wrap">
            <div class="btn_wrap_pd">
                <button type="submit" class="btn btn_submit J_ajax_submit_btn">提交</button>
            </div>
        </div>
    </form>

    <!-- end -->

</div>

<?php $this->footer(); ?>